package com.gateway.springboot.starter.plugin.tenant;

import com.gateway.plugin.api.GatewayPlugin;
import com.gateway.plugin.base.handler.PluginDataHandler;
import com.gateway.plugin.tenant.CnameTenantGatewayPlugin;
import com.gateway.plugin.tenant.TenantGatewayPlugin;
import com.gateway.plugin.tenant.handle.TenantPluginDataHandler;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @program: api-gateway
 * @description:
 * @author: YuKai Fan
 * @create: 2025/2/6 16:21
 **/
@Configuration
public class TenantPluginConfiguration {

    @Bean
    public GatewayPlugin tenantGatewayPlugin() {
        return new TenantGatewayPlugin();
    }

//    @Bean
//    public GatewayPlugin cnameTenantGatewayPlugin() {
//        return new CnameTenantGatewayPlugin();
//    }

    @Bean
    public PluginDataHandler tenantPluginDataHandler() {
        return new TenantPluginDataHandler();
    }
}
